<?php
	namespace app\index\controller;
	use think\Controller;
	use think\Request;
	class Base extends  Controller{
		//存储需要登陆的页面
		
		public function _initialize(){
			
			if(!$this->isLogin()&&((in_array(Request::instance()->action(), $this->is_check_login))||($this->is_check_login[0]=='*')))
			{
				$this->error('请先登陆','index/Index/login');
			};
		}
		public function isLogin(){
			return session('?name');
		}
	}
?>